<?php
class QkModel extends Action{
	//test
	//公版
	public function getqkoby($qkdate,$qktuoyunno,$qkcustomernm,$qkcustomercp,$qkprovince,$qkcargoaddress,$qkyewubumen,$qksendmethod,$qkjianshu,$qkdetail,$qkzhongzhuanzhuanxian,$qkzhongzhuanno,$qkzhuanxianmethod,$qkprocessresult){
		$info=collectinfo(__METHOD__,'',array());
				
		$qk=M('qk');
		$qko=$qk->where("qkdate='".$qkdate."' AND qktuoyunno='".$qktuoyunno."' AND qkcustomernm='".$qkcustomernm."' AND qkcustomercp='".$qkcustomercp."' AND qkprovince='".$qkprovince."' AND qkcargoaddress='".$qkcargoaddress."' AND qkyewubumen='".$qkyewubumen."' AND qksendmethod='".$qksendmethod."' AND qkjianshu='".$qkjianshu."' AND qkdetail='".$qkdetail."' AND qkzhongzhuanzhuanxian='".$qkzhongzhuanzhuanxian."' AND qkzhongzhuanno='".$qkzhongzhuanno."' AND qkprocessresult='".$qkprocessresult."'")->find();
		
		return createarrok('ok',$qko,'',$info);
	}
	
	//公版
	public function add($get){
		$info=collectinfo(__METHOD__,'$get',array($get));
		if(isset($get)===false){return createarrerr('error_code','get 不能为空',$info);}//防止NULL
		
		$qk=M('qk');
		$qk->data($get)->add();

		return createarrok('ok',$data,'',$info);
	}

} 
?>